package com.cg.service;

import com.cg.entity.Product;
import com.cg.mapper.ProductMapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class ProductService {

    @Autowired
    ProductMapper productMapper;

    public Product selectProductById(Integer id){
        return productMapper.selectProductById(id);
    }

    public List<Product> selectProductList(Product product){
        return productMapper.selectProductList(product);
    }

    public Integer updateProduct(Product product){
        return productMapper.updateProduct(product);
    }
}
